package com.design_patterns.adapter;

import java.io.BufferedReader;
import java.io.FileInputStream;
import java.io.InputStreamReader;

/**
 * @author: 李德才
 * @description:
 * @create: 2020-09-19 15:37
 **/

public class Main {
    public static void main(String[] args) throws Exception {

        FileInputStream fis = new FileInputStream("src/main/resources/index.html");
//        中间加一层，适配
        InputStreamReader isr = new InputStreamReader(fis);
        BufferedReader br = new BufferedReader(isr);
        String line = br.readLine();
        while (null != line && !"".equals(line)) {
            System.err.println(line);
            line = br.readLine();
        }
        br.close();
    }
}